﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Line : MonoBehaviour
{
    private LineRenderer _lineRenderer;

    public void DrawLine(Vector3 from, Vector3 to)
    {
        _lineRenderer.startWidth = 0.1f;
        _lineRenderer.SetPosition(0, from);
        _lineRenderer.SetPosition(1, to);
    }

    public void ClearLine()
    {
        _lineRenderer.SetPosition(0, Vector3.zero);
        _lineRenderer.SetPosition(1, Vector3.zero);
    }

    void Start()
    {
        _lineRenderer = gameObject.GetComponent<LineRenderer>();
    }

    void Update()
    {
    }
}